//---------------------------------------------------------------------------
/**
 * \class CFileManager
 * \brief This is an implemented  traversal class to manage file & directory
 * \version 0.1
 *
 * \author Woo-Hyun Kim (woorung@nhncorp.com, woorung@gmail.com)
 * \author http://blog.naver.com/wisereign .
 *
 * \date 2006/09/27
 */
//---------------------------------------------------------------------------
#ifndef CFileManagerH
#define CFileManagerH
//---------------------------------------------------------------------------
#include <iostream>
#include <iterator>
#include <vector>
#include <list>
#include <map>
#include <algorithm>
#include <fstream>
#include <string>

#include <strings.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <dirent.h>
#include <limits.h>

#include "CFileWalker.h"

using namespace std;
//---------------------------------------------------------------------------
class CFileManager : public CFileWalker {
private :
	vector<string> dirs;
	vector<string> files;

	bool DirectoryProcess(char *current_fblock_name);
	bool RegularProcess(char *current_fblock_name);
	bool BlockProcess(char *current_fblock_name);
	bool CharProcess(char *current_fblock_name);
	bool FifoProcess(char *current_fblock_name);
	bool FlnkProcess(char *current_fblock_name);
	bool SockProcess(char *current_fblock_name);
	bool FdirProcess(char *current_fblock_name);

public :
	CFileManager();
	virtual ~CFileManager();

	vector<string> &getDirs(vector<string> &dirs);
	vector<string> &getFiles(vector<string> &files);
};
//---------------------------------------------------------------------------
#endif
